// dlg.txt

begintalkscript;

variables;

begintalknode 1;
	state = -1;
	nextstate = -1;
	condition = get_sdf(18,2) == 0;
	question = "special";
	text1 = "You enter the Murkwood. These are lowlands at the northwest corner of the Mera Fen. Fog tends to accumulate in this depression at the base of the mountains, leaving these woods gray and dim for most of the year.";
	text2 = "Though the woods are quiet and still, you can't shake the feeling that someone is watching you. Of course, you suspect that this bit of paranoia afflicts everyone who passes through.";
	action = SET_SDF 18 2 1;

begintalknode 2;
	state = -1;
	nextstate = -1;
	condition = get_sdf(18,3) == 0 && gf(18,7) == 0 && gf(18,6) == 0;
	question = "special";
	text1 = "Just ahead, you can see a group of brigands. They aren't ordinary refugees. They're well-fed and heavily armed. They also see you coming.";
	text2 = "They don't attack you right away, but they are ready to fight if you intrude upon their territory.";
	action = SET_SDF 18 3 1;

begintalknode 3;
	state = -1;
	nextstate = -1;
	condition = get_sdf(18,4) == 0;
	question = "special";
	text1 = "Someone built this door recently. It's thick, sturdy wood, and extra attention was paid to making a very secure lock. The keyhole glows slightly. Perhaps there is an enchantment too.";
	text2 = "When you get close, you think that you hear shouting coming from the other side of the door. Someone is having an argument. It only lasts for a few moments. Then they walk away.";
	action = SET_SDF 18 4 1;

begintalknode 4;
	state = -1;
	nextstate = -1;
	condition = get_sdf(18,5) == 0 && gf(18,7) == 0 && char_ok(30);
	question = "special";
	text1 = "You are at the entrance of the storage cave Emogene told you about. If you are caught in there, your fragile truce is at an end.";
	action = SET_SDF 18 5 1;

begintalknode 5;
	state = -1;
	nextstate = -1;
	condition = get_sdf(18,8) == 0;
	question = "special";
	text1 = "There is a rough Shaping workshop in here. It must have required some effort to get these supplies out here. It's a crude workshop. It appears to have only been used for one job. Then the power spirals exploded.";
	text2 = "You can't be sure, but you suspect that this was where the glass orbs Baston used, the orbs that created creations when shattered, were made. It must have taken a full Shaper to do this work.";
	action = SET_SDF 18 8 1;

begintalknode 6;
	state = -1;
	nextstate = -1;
	condition = 1;
	question = "special";
	text1 = "The sign says:";
	text2 = "  KEEP OUT OR DIE!!!!!";


begintalknode 7;
	state = -1;
	nextstate = -1;
	condition = 1;
	question = "special";
	text1 = "This weathered and splintered old sign says:";
	text2 = "  Darnley's Common House";
	text3 = "  Travelers Welcome";

begintalknode 8;
	state = -1;
	nextstate = -1;
	condition = 1;
	question = "special";
	text1 = "This sign says:";
	text2 = "  Penta - West";
	text3 = "  Mera - East";
	text4 = "  Coast Pass - Southwest";

begintalknode 10;
	state = -1;
	nextstate = -1;
	condition = 1;
	question = "special";
	text1 = "You see what is a depressingly familiar sight in these chaotic times. An armed, dirty person standing at the crossroads, waiting for travelers. A brigand or petty thug, ready to extort passers-by.";
	text2 = "The difference is that this woman is smarter than most. When she sees you, she realizes that you are a difficult target. She turns and runs down the northern path.";

begintalknode 12;
	state = -1;
	nextstate = 10;
	condition = 1;
	question = "Name";
	text1 = "You are at the entrance to a bandit camp. A motley assortment of thugs, escaped serviles, and armed refugees are clustered around cooking fires, trying to stave off the chill of the mist. When you come into view, weapons are drawn.";
	text2 = "Before you can get much farther, the woman you saw at the crossroads runs up and stops you. _Hold there, traveler. I am Emogene, and these are our lands. None pass through without our permission. None enter our camp without mine._";
	text3 = "_We have no quarrel with you. We'll let you travel down the road free of charge. You won't enter here without permission, though._ She draws her baton to emphasize the point.";
	text5 = "Emogene and the other brigands watch you nervously. None of them want to fight you. They're dirty and exhausted, but they aren't fools.";
	action = INTRO;

begintalknode 13;
	state = 10;
	nextstate = 11;
	condition = 1;
	question = "What are you doing out here?";
	text1 = "_Trying to make a living in difficult times. That is all. We keep the roads clear of rogue creations and villains. In return for this difficult service, we require a fee of those who would pass._";
	text2 = "_Of course, as I said, you will not need to pay._";

begintalknode 14;
	state = 11;
	nextstate = -1;
	condition = 1;
	question = "So you extort money from refugees and travelers?";
	text1 = "_I object to the word 'extort.' It is an ugly term. We are helping them. If they are so tight with their coins that they can't pay us for this service, it is good that we are here to teach them manners._";

begintalknode 15;
	state = 11;
	nextstate = -1;
	condition = 1;
	question = "What happens to those who don't pay you?";
	text1 = "_Oh, they pay us. As they should. As is fair. And if we are forced to, we teach them manners by making them pay more than they would have to otherwise._";
	text2 = "_But we are not violent unless forced. And this is no concern of yours. You are not one of Astoria's soldiers._";

begintalknode 16;
	state = 10;
	nextstate = -1;
	condition = 1;
	question = "Can I trade with you?";
	text1 = "She looks at your equipment. She is clearly envious. For a moment, she reconsiders whether to rob you. Then she shakes her head.";
	text2 = "_We just want you to go._";

begintalknode 17;
	state = 10;
	nextstate = -1;
	condition = 1;
	question = "You're going to stop extorting travelers.";
	text1 = "_Oh, really? We don't want to fight you, but we will if you force us. And what do you care if the occasional band of refugees loses a ring or a handful of coins? It is not your concern._";
	text2 = "_Go. If you enter our camp, we will force you to leave._";
	action = END_TALK;
	
begintalknode 18;
	state = 10;
	nextstate = 12;
	condition = gf(12,2) == 3 && gf(18,6) == 0;
	question = "I am hunting the Murkwood. I'm looking for information about someone called Baston.";
	text1 = "She shakes her head. _I don't know any Baston. Not one of mine. You're going to have to go somewhere else._";
	text2 = "You believe that she doesn't know Baston, but she is clearly hiding something. Something in the woods to the north.";
	code =
		if (get_stat(20) < 4)
			rs(2);
	break;
		
begintalknode 19;
	state = 12;
	nextstate = -1;
	condition = 1;
	question = "Astoria herself sent me to investigate.";
	text1 = "_Well, Astoria isn't here. It would take a Shaper to get us to let you into our camp._";
	
begintalknode 20;
	state = 12;
	nextstate = -1;
	condition = 1;
	question = "I will need to search your grove.";
	text1 = "_Oh, really? We don't want to fight you, but we don't know anything about your Baston. You aren't coming in._";
	text2 = "_Go. If you enter our camp, we will force you to leave._";
	action = END_TALK;

begintalknode 21;
	state = 12;
	nextstate = 13;
	condition = get_stat(20) > 6;
	question = "Baston attempted to assassinate Astoria. If you are smart, you will help my search.";
	text1 = "Astoria wanted you to keep the assassination attempt quiet, but there only seems to be one way to avoid bloodshed. Emogene suddenly becomes very pale.";
	text2 = "_They tried ... kill ... A member of the Council? Those ... I didn't know anything about this!_";

begintalknode 22;
	state = 12;
	nextstate = -1;
	condition = 1;
	question = "All right. I'm leaving.";
	text1 = "_Good. Go. But don't forget. If you enter our camp, we will force you to leave._";
	action = END_TALK;

begintalknode 23;
	state = 13;
	nextstate = 14;
	condition = 1;
	question = "About what?";
	text1 = "_Ten people. Humans. They asked us if they could stay in the caves. Said they were deserters. Paid us. We let them in. Didn't ask questions._";

begintalknode 24;
	state = 14;
	nextstate = -1;
	condition = 1;
	question = "Where were they from?";
	text1 = "_They never said. We didn't ask._";

begintalknode 25;
	state = 14;
	nextstate = -1;
	condition = 1;
	question = "Where are these caves?";
	text1 = "She points to the north. _Just on the other side of our camp. The first thing they did was build doors in the entrances, though. You might not be able to get in._";

begintalknode 26;
	state = 14;
	nextstate = -1;
	condition = 1;
	question = "Was one of them Baston? (Describe him.)";
	text1 = "_They all wore cloaks with hoods. They made sure we didn't see them. Yes, I know. It was suspicious. But they were paying us._";
	text2 = "She thinks. _They also had three wagons full of stuff. All covered up. Some of it hummed slightly. We didn't ask what was under the canvas. As long as they paid, not our business._";
	
begintalknode 27;
	state = 14;
	nextstate = -1;
	condition = 1;
	question = "You will let me into their caves. Now.";
	text1 = "She steps out of the way. She seems lost in thought, no doubt already planning her band's departure from the Murkwood. Being implicated in the attempted assassination of a Council member terrifies her.";
	text2 = "_You can pass. Look for doors in the cliff face. That's where they are. We didn't have anything to do with it. I give you my word!_";
	text3 = "_Oh, and one other thing. There is another cave well to the east. It doesn't have a door. That place is ours. Stay out of it, or our little peace will come to a sudden end._";
	text4 = "She turns and walks to the others, no doubt to plan her little band's flight from this area. You suspect that, within a day, they will have placed a healthy distance between themselves and here.";
	action = END_TALK;
	code =
		award_party_xp(150,6);
		sf(18,6,1);
	break;
	
begintalknode 28;
	state = 10;
	nextstate = -1;
	condition = gf(12,8) == 1 && gf(19,2) == 0 && gf(18,6) == 0;
	question = "I am hunting the bandit Bennhold. Do you know where he is?";
	text1 = "_I might know something. I also might not. This is our land, and we want to keep peaceful relations with those near us. Especially those allied to the most deadly bandit in Terrestia._";
	text2 = "_I'm not saying anything._";

begintalknode 29;
	state = 10;
	nextstate = 16;
	condition = gf(12,8) == 1 && gf(19,2) == 0 && gf(18,6) > 0;
	question = "I am hunting the bandit Bennhold. Do you know where he is?";
	text1 = "_I might know something. I also might not. Since I plan to disappear very soon, I need money, and I don't care if I irritate anyone nearby._";
	text2 = "_Give me two hundred coins, and I'll tell you what I know._";

begintalknode 30;
	state = 16;
	nextstate = -1;
	condition = get_stat(20) > 8 && gf(19,2) == 0;
	question = "How about this? Tell me what you know and you won't die right here and now.";
	text1 = "Your bluff is an effective one. Emogene is thoroughly terrified.";
	text2 = "_Go south into the Mera. Go down the road to the west. Look for the path into the trees marked with skulls._";
	text3 = "_There is a hidden way at the end of that path. That leads to where Bennhold is. I've never seen him, but I know that's where he is. That's why we pay them. We don't want to get our throats slit._";
	code =
		sf(19,2,1);
		award_party_xp(100,8);
	break;

begintalknode 31;
	state = 16;
	nextstate = -1;
	condition = coins_amount() >= 200 && gf(19,2) == 0;
	question = "Fine. (Pay her.)";
	text1 = "You count out the coins. Emogene smiles. _Good. This makes up for some of the money they've bled from us over the months._";
	text2 = "_Go south into the Mera. Go down the road to the west. Look for the path into the trees marked with skulls._";
	text3 = "_There is a hidden way at the end of that path. That leads to where Bennhold is. I've never seen him, but I know that's where he is. That's why we pay them. We don't want to get our throats slit._";
	code =
		sf(19,2,1);
		award_party_xp(100,8);
	break;

begintalknode 32;
	state = 16;
	nextstate = -1;
	condition = get_stat(20) < 8 && gf(19,2) == 0;
	question = "How about this? Tell me what you know and you won't die right here and now.";
	text1 = "Your bluff is ineffective. Emogene is unimpressed.";

begintalknode 33;
	state = 16;
	nextstate = 10;
	condition = 1;
	question = "I want to know something else.";
	text1 = "_You can ask. I don't have to answer._";


begintalknode 34;
	state = 10;
	nextstate = -1;
	condition = gf(22,11) == 1;
	question = "I am trying to find the bandits in the fens to the south.";
	text1 = "Emogene suddenly looks very nervous. _Bandits? To the south? Don't know anything about them. I can't help you._";
	text2 = "She is clearly lying, but you doubt that you can force her to tell the truth. Of course, some information might be hidden in their camp, but these brigands wouldn't appreciate you looking for it.";
	
begintalknode 35;
	state = 10;
	nextstate = -1;
	condition = 1;
	question = "All right. I'm leaving.";
	text1 = "_Good. Go._";
	text2 = "_But don't forget. If you enter our camp, we will force you to leave._";
	action = END_TALK;
	code =
		if (gf(18,6) > 0)
			rs(2);
	break;
	
//


begintalknode 40;
	state = -1;
	nextstate = -1;
	condition = gf(18,7) == 0 && gf(18,6) == 0;
	question = "special";
	text1 = "When you step into the bandit camp, the reaction is immediate. The weapons come out. They shout and charge. They didn't want to fight you, but they aren't going to let you escape and report their presence to the authorities either.";
	code =
		sf(18,7,1);
		make_zone_hostile();
	break;
	
begintalknode 41;
	state = -1;
	nextstate = -1;
	condition = 1;
	question = "special";
	text1 = "The guard in the bandits' treasure cave sees you. He shouts an alarm.";

begintalknode 42; // bennhold letter
	state = -1;
	nextstate = -1;
	condition = 1;
	question = "special";
	text1 = "You find a bunch of junk that the bandits liberated from passing refugees. Pipes. Silverware. Glassware. Little of value.";
	text2 = "You also find a letter, probably left here by mistake. It reads:";
	text3 = "_Emogene - I will generously allow you to continue your work. All I ask is a hundred coins a week for the privilege of using the Murkwood._";
	text4 = "_Of course, you will bring payment to my servant Crenshaw. None see me but my most trusted lieutenants. To reach him, enter the fen to the south. Walk to the end of the skull-marked path. The way is concealed._";
	text5 = "_Do not consider defying me, or one morning you will simply not wake up._";
	text6 = "_-Bennhold._";
	text7 = "You take note of this. Should you ever be down there, you have a better idea of where to look if you want to hunt bandits.";
	code =
		if (gf(19,2) == 0) {
			sf(19,2,1);
			}
			else rs(7);
	break;
	
begintalknode 43; // assasin papers
	state = -1;
	nextstate = -1;
	condition = 1;
	question = "special";
	text1 = "You look through the box, sorting through the few papers that evaded destruction. Sadly, most of the useful information was already destroyed. Names. Locations. Specific plans. All gone.";
	text2 = "You only find one interesting letter, one scrap that was next in line for burning. It says,";
	text3 = "_Baston - Yes, I will use this name when I write you. We will not regain our true names until the traitor is dead. I hope that you survive your mission and can see that day._";
	text4 = "_I will not lie to you. You will probably not survive the attack. Do not put us at risk. Destroy your papers. Destroy the key. Die before capture._";
	text5 = "_Should you survive, I will meet you at Kratoa-Kel. Once there, it will be easy to ferry you to safety._";
	text6 = "The letter is unsigned.";
	code =
		sf(18,1,1);
	break;
	
begintalknode 44;
	state = -1;
	nextstate = -1;
	condition = 1;
	question = "special";
	text1 = "The other bandits are ignoring you. Emogene speaks for them.";
	
begintalknode 45;
	state = -1;
	nextstate = -1;
	condition = 1;
	question = "special";
	text1 = "The clawbug hisses and clicks at you when you get close. You back away.";	
	
begintalknode 46; // argue
	state = -1;
	nextstate = -1;
	condition = 1;
	question = "special";
	text1 = "There are several people hiding in this cave. They are not ordinary brigands or thugs. They are well-armed and trained. They aren't covered in filth.";
	text2 = "They are also in a panic. They are arguing with each other, trying to decide whether they should flee or hide here. You hear one of them say, _We knew he would fail. Now she's going to hunt us all ..._";
	text3 = "Then they see you.";
	
	
begintalknode 47; // suicide
	state = -1;
	nextstate = -1;
	condition = 1;
	question = "special";
	text1 = "There is one man out in this clearing. He wears the robes of a Shaper. They are tattered and worn, but the symbol is still visible.";
	text2 = "He is quickly and carefully destroying a box full of documents. He pulls a sheaf of papers out, gives them a quick glance, and casts them into the fire.";
	text3 = "Then he sees you. He doesn't look surprised. He only says one thing. _I knew it would come to this. I thought I would have more time._ Then he makes a short motion with his hand.";
	text4 = "You raise your weapon, ready to defend yourself. The Shaper isn't going to fight you. Instead, he grabs his stomach, collapses to the floor, and begins to writhe in agony.";
	text5 = "Whoever he is, he will not be taken alive.";
	code =
		force_char_status(39,6,50);
	break;
	
begintalknode 48;
	state = -1;
	nextstate = -1;
	condition = 1;
	question = "special";
	text1 = "__";
	
	//

begintalknode 50;
	state = -1;
	nextstate = 50;
	condition = 1;
	question = "Name";
	text1 = ".";
	text2 = "";
	text5 = ".";
	action = INTRO;

begintalknode 51;
	state = 50;
	nextstate = -1;
	condition = 1;
	question = "";
	text1 = ".";
	text2 = "";

	
begintalknode 52;
	state = 50;
	nextstate = -1;
	condition = 1;
	question = "";
	text1 = ".";
	text2 = "";
	
begintalknode 53;
	state = 50;
	nextstate = -1;
	condition = 1;
	question = "";
	text1 = ".";
	text2 = "";
	
begintalknode 54;
	state = 50;
	nextstate = -1;
	condition = 1;
	question = "";
	text1 = ".";
	text2 = "";
	
begintalknode 55;
	state = 50;
	nextstate = -1;
	condition = 1;
	question = "";
	text1 = ".";
	text2 = "";
	
begintalknode 56;
	state = 50;
	nextstate = -1;
	condition = 1;
	question = "";
	text1 = ".";
	text2 = "";
	
begintalknode 57;
	state = 50;
	nextstate = -1;
	condition = 1;
	question = "";
	text1 = ".";
	text2 = "";
	
begintalknode 58;
	state = 50;
	nextstate = -1;
	condition = 1;
	question = "";
	text1 = ".";
	text2 = "";

begintalknode 59;
	state = 50;
	nextstate = -1;
	condition = 1;
	question = "";
	text1 = ".";
	text2 = "";

begintalknode 60;
	state = 50;
	nextstate = -1;
	condition = 1;
	question = "";
	text1 = ".";
	text2 = "";

begintalknode 61;
	state = 50;
	nextstate = -1;
	condition = 1;
	question = "";
	text1 = ".";
	text2 = "";

begintalknode 62;
	state = 50;
	nextstate = -1;
	condition = 1;
	question = "";
	text1 = ".";
	text2 = "";

begintalknode 63;
	state = 50;
	nextstate = -1;
	condition = 1;
	question = "";
	text1 = ".";
	text2 = "";

begintalknode 64;
	state = 50;
	nextstate = -1;
	condition = 1;
	question = "";
	text1 = ".";
	text2 = "";

//

begintalknode 70;
	state = -1;
	nextstate = 70;
	condition = 1;
	question = "Name";
	text1 = ".";
	text2 = "";
	text5 = ".";
	action = INTRO;

begintalknode 71;
	state = 70;
	nextstate = -1;
	condition = 1;
	question = "";
	text1 = ".";
	text2 = "";

//

begintalknode 90;
	state = -1;
	nextstate = 90;
	condition = 1;
	question = "Name";
	text1 = ".";
	text2 = "";
	text5 = ".";
	action = INTRO;

begintalknode 91;
	state = 90;
	nextstate = -1;
	condition = 1;
	question = "";
	text1 = ".";
	text2 = "";
		